<nz-card [nzBordered]="false">
  <form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm()">
    <nz-form-item>
      <nz-form-label [nzSpan]="6" nzRequired nzFor="introduceTitle">介绍标题</nz-form-label>
      <nz-form-control [nzSpan]="10" [nzValidateStatus]="validateForm.controls['introduceTitle']">
        <input type="text" nz-input formControlName="introduceTitle" placeholder="介绍标题">
        <nz-form-explain *ngIf="validateForm.get('introduceTitle').dirty && validateForm.get('introduceTitle').hasError('required')">请输入介绍标题</nz-form-explain>
        <nz-form-explain *ngIf="validateForm.get('introduceTitle').dirty && validateForm.get('introduceTitle').hasError('maxlength')">不能超过60个字</nz-form-explain>
      </nz-form-control>
    </nz-form-item>
    <nz-form-item>
      <nz-form-label [nzSpan]="6" nzFor="introduceVideoKey">介绍视频</nz-form-label>
      <nz-form-control [nzSpan]="8" [nzValidateStatus]="validateForm.controls['introduceVideoKey']">
        <input type="text" nz-input formControlName="introduceVideoKey" placeholder="介绍视频" style="display: none;"><!-- -->
        <!--<input type="file" nz-input id="uploadVideo" (change)="onAfterSelect($event)">-->
        <nz-upload style="display: inline-block;"
                   [nzBeforeUpload]="beforeUpload"
                   [nzSize]="2048000"
                   nzAccept="video/*,.mp4,MP4">
          <button nz-button type="button" *ngIf="!entity.videoName">
            <i class="anticon anticon-upload"></i><span>{{btnText}}</span>
          </button>
          <span *ngIf="entity.introduceVideoName && !uploading" title="点击可修改视频" style="border: 1px solid #d9d9d9;line-height: 1.5;padding: 6px 10px;border-radius: 5px;cursor:pointer;">{{entity.introduceVideoName}}</span>
          <span *ngIf="entity.introduceVideoName && uploading" title="点击可修改视频" style="border: 1px solid #d9d9d9;line-height: 1.5;padding: 6px 10px;border-radius: 5px;cursor:pointer;">{{btnText}}</span>
        </nz-upload>
        <nz-popconfirm [nzTitle]="'确定要删除视频吗？'" (nzOnConfirm)="deleteFile()" >
          <a nz-popconfirm style="margin-left: 15px;display: inline-block;color: #ff0000;" *ngIf="entity.introduceVideoName && !uploading">删除视频</a>
        </nz-popconfirm>
        <nz-form-explain *ngIf="validateForm.get('introduceVideoKey').dirty && validateForm.get('introduceVideoKey').hasError('required')">
          请选择介绍视频
        </nz-form-explain>
      </nz-form-control>
      <nz-form-label [nzSpan]="10"></nz-form-label><!--占位-->
      <nz-form-label [nzSpan]="6" style="visibility: hidden;"></nz-form-label><!--占位-->
      <nz-form-extra style="color: orange;display: inline-block;padding-top: 13px;">最大可上传1000MB大小的视频；鉴于小程序支持效果，我们建议您上传mp4格式的视频</nz-form-extra>
    </nz-form-item>
    <nz-form-item>
      <nz-form-label [nzSpan]="6" nzRequired nzFor="introduceDescription">
        介绍图
      </nz-form-label>
      <!--<button nz-button type="button" nzType="dashed" (click)="editorContent()"><i class="anticon anticon-edit"></i>点击编辑商品详情</button>-->
      <nz-form-control [nzSpan]="10" [nzValidateStatus]="validateForm.controls['introduceDescription']" class="content-class">
        <textarea rows="6" nz-input formControlName="introduceDescription" placeholder="介绍图" style="display: none;"></textarea>
        <div id="content-section" title="点击可进行编辑修改介绍图" (click)="showEdit()" style="text-align: center;display:block;height: 582px;border: 1px solid #d9d9d9;overflow-y: auto;cursor: pointer;" #content></div>
        <nz-form-explain *ngIf="validateForm.get('introduceDescription').dirty && validateForm.get('introduceDescription').hasError('required')">请输入介绍图</nz-form-explain>
      </nz-form-control>
    </nz-form-item>
    <div nz-form-item nz-row  style="text-align: center;border-top: 1px solid #d0d0d0; padding-top: 12px;">
      <button nz-button type="submit" [nzType]="'primary'" >保存</button>
    </div>
  </form>
  <full-screen-editor [contentVal]="entity.introduceDescription" (close)="showEdit()" (contentCallback)="contentCallback($event)" *ngIf="isShow"></full-screen-editor>
</nz-card>
